package cn.tedu;


import com.alibaba.druid.pool.DruidDataSource;
import com.alibaba.druid.pool.DruidPooledConnection;

import java.sql.SQLException;

public class Demo02 {
    public static void main(String[] args) throws SQLException {
        DruidDataSource dds = new DruidDataSource();
        dds.setUrl("jdbc:mysql://localhost:3306/newdb3?characterEncoding=utf8&serverTimezone=Asia/Shanghai");
        dds.setUsername("root");
        dds.setPassword("root");
        dds.setInitialSize(3);
        dds.setMaxActive(5);
        DruidPooledConnection conn = dds.getConnection();
    }
}
